<?php require VIEW_ROOT.'/common/header.php'?>

<style>
.top { color:#ff0000; }
</style>

<div class="info">
	程序点击排行
</div>

<table>
	<tr>
		<th width="50">排名</th>
		<th width="100">Controller</th>
		<th width="150">Action</th>
		<th width="70">点击</th>
		<th>最后访问</th>
	</tr>
	<?php $i = 0?>
	<?php foreach ($res as $row) {?>
		<tr>
			<td><b><?php echo ++$i <= 3 ? "<span class='top'>$i</span>" : $i?></b></td>
			<td><?php echo $row['controller']?></td>
			<td><?php echo '<b>'.$row['action'].'</b>'?></td>
			<td><?php echo $row['hits']?></td>
			<td class="frm"><?php echo date('Y-m-d H:i:s', $row['last'])?></td>
		</tr>
	<?php }?>
</table>

<?php require VIEW_ROOT.'/common/footer.php'?>